#define _CRT_SECURE_NO_WARNINGS 1
#include <stdio.h>
int main()
{
	int cnt = 0;
	for (int i = 1; i <= 100; i++)
	{
		int k = i;
		do {
			if (k % 10 == 9)
			{
				cnt++;
			}
			k /= 10;
		} while (k);
	}

	printf("%d\n", cnt);
	return 0;
}